<template>
  <el-card>
    <el-tabs v-model="activeName" @tab-click="handleClick">
      <el-tab-pane v-for="item in typeList" :label="item.typeName" :name="item.typeCode">
        <down-box v-for="item1 in item.parameterList" v-bind:apiPath="item1.styleType==='select'?item1.selectUrl:null"
                  v-bind:type="true"
                  v-bind:inputInfo="item1"></down-box>
      </el-tab-pane>
    </el-tabs>
  </el-card>

</template>

<script>
import downBox from '../component/CommonDropDownBox'
import {parameterList} from '../../api/dictApi'

export default {
  data() {
    return {
      activeName: 'sys_parameter',
      typeList: [],
    };
  },
  methods: {
    handleClick(tab, event) {
      console.log(tab, event);
    },
    parameterListAll() {
      parameterList().then(res => {
        this.typeList = res.data.dataList
      })
    }
  },
  created() {
    this.parameterListAll()
  },
  components: {
    downBox
  }
};
</script>

<style scoped>

</style>
